package yxy.game.pm2.bean.currency;

import java.util.ArrayList;

public enum CurrencyType {

    CT_元宝(1, CurrencyGroup.POINT), //
    CT_钱币(2, CurrencyGroup.POINT), //
    CT_武将经验(3, CurrencyGroup.POINT), //
    CT_主公经验(4, CurrencyGroup.POINT), //
    CT_物品(5, CurrencyGroup.ITEM), //
    CT_武将(6, CurrencyGroup.HERO), //
    CT_装备(7, CurrencyGroup.ITEM), //
    CT_碎片(8, CurrencyGroup.ITEM), //
    CT_魂玉(9, CurrencyGroup.SOUL), //
    CT_天书(10, CurrencyGroup.ITEM), //
    CT_玉石(11, CurrencyGroup.ITEM), //
    CT_情报(12, CurrencyGroup.POINT), //
    CT_友情点(13, CurrencyGroup.POINT), //
    CT_武将精魄(14, CurrencyGroup.POINT), //
    CT_过关斩将积分(15, CurrencyGroup.POINT), //
    CT_竞技场积分(16, CurrencyGroup.POINT), //
    CT_联盟积分(17, CurrencyGroup.POINT), //
    CT_锦盒积分(18, CurrencyGroup.POINT), //
    CT_招募积分(19, CurrencyGroup.POINT), //
    CT_将魂(20, CurrencyGroup.POINT), //
    CT_装扮券(21, CurrencyGroup.POINT), //
    CT_招贤积分(25, CurrencyGroup.POINT), //
    CT_称号(22, CurrencyGroup.SIGN), //
    CT_头像(26, CurrencyGroup.SIGN), //
    CT_头像框(23, CurrencyGroup.SIGN), //
    CT_形象(24, CurrencyGroup.SIGN), //
    CT_VIP经验(27, CurrencyGroup.POINT), //
    CT_普通夺宝积分(28, CurrencyGroup.POINT), //
    CT_高级夺宝积分(29, CurrencyGroup.POINT), //
    CT_联盟战积分(30, CurrencyGroup.POINT), //
    CT_天梯积分(31, CurrencyGroup.POINT), //
    CT_平叛积分(32, CurrencyGroup.POINT), //
    CT_限时兑换积分(35, CurrencyGroup.POINT), //
    CT_金锭(38, CurrencyGroup.POINT), //
    CT_节日BOSS积分(39, CurrencyGroup.POINT), //
    CT_节日BOSS兑换卷(40, CurrencyGroup.POINT), //

    CT_周卡_货币1(37, CurrencyGroup.POINT), //营养水 种树
    CT_周卡_货币2(36, CurrencyGroup.POINT), //树神水晶
    CT_兵符(41, CurrencyGroup.PickedTroopsSlot); //兵符


    private int number;
    private CurrencyGroup group;

    private CurrencyType(int number, CurrencyGroup group) {
        this.number = number;
        this.group = group;
    }

    //按组获取类型名
    public static ArrayList<CurrencyType> getCurrencyTypeByGroup(CurrencyGroup group) {
        ArrayList<CurrencyType> cts = new ArrayList<>();
        switch (group) {
            case ITEM:
                cts.add(CurrencyType.CT_物品);
                cts.add(CurrencyType.CT_装备);
                cts.add(CurrencyType.CT_碎片);
                cts.add(CurrencyType.CT_天书);
                cts.add(CurrencyType.CT_玉石);
                return cts;
            case SIGN:
                cts.add(CurrencyType.CT_称号);
                cts.add(CurrencyType.CT_头像);
                cts.add(CurrencyType.CT_头像框);
                cts.add(CurrencyType.CT_形象);
                return cts;
            case POINT:
                cts.add(CurrencyType.CT_元宝);
                cts.add(CurrencyType.CT_钱币);
                cts.add(CurrencyType.CT_武将经验);
                cts.add(CurrencyType.CT_主公经验);
                cts.add(CurrencyType.CT_情报);
                cts.add(CurrencyType.CT_友情点);
                cts.add(CurrencyType.CT_武将精魄);
                cts.add(CurrencyType.CT_过关斩将积分);
                cts.add(CurrencyType.CT_竞技场积分);
                cts.add(CurrencyType.CT_联盟积分);
                cts.add(CurrencyType.CT_锦盒积分);
                cts.add(CurrencyType.CT_招募积分);
                cts.add(CurrencyType.CT_将魂);
                cts.add(CurrencyType.CT_装扮券);
                cts.add(CurrencyType.CT_招贤积分);
                cts.add(CurrencyType.CT_VIP经验);
                cts.add(CurrencyType.CT_普通夺宝积分);
                cts.add(CurrencyType.CT_高级夺宝积分);
                cts.add(CurrencyType.CT_联盟战积分);
                cts.add(CurrencyType.CT_天梯积分);
                cts.add(CurrencyType.CT_平叛积分);
                cts.add(CurrencyType.CT_限时兑换积分);
                cts.add(CurrencyType.CT_金锭);
                cts.add(CurrencyType.CT_节日BOSS积分);
                cts.add(CurrencyType.CT_节日BOSS兑换卷);
                cts.add(CurrencyType.CT_周卡_货币1);
                cts.add(CurrencyType.CT_周卡_货币2);
                return cts;
            default:
                return null;
        }
    }

    public int getNumber() {
        return number;
    }

    public CurrencyGroup getGroup() {
        return group;
    }

    static public CurrencyType forNumber(int number) {
        switch (number) {
            case 1:
                return CT_元宝;
            case 2:
                return CT_钱币;
            case 3:
                return CT_武将经验;
            case 4:
                return CT_主公经验;
            case 5:
                return CT_物品;
            case 6:
                return CT_武将;
            case 7:
                return CT_装备;
            case 8:
                return CT_碎片;
            case 9:
                return CT_魂玉;
            case 10:
                return CT_天书;
            case 11:
                return CT_玉石;
            case 12:
                return CT_情报;
            case 13:
                return CT_友情点;
            case 14:
                return CT_武将精魄;
            case 15:
                return CT_过关斩将积分;
            case 16:
                return CT_竞技场积分;
            case 17:
                return CT_联盟积分;
            case 18:
                return CT_锦盒积分;
            case 19:
                return CT_招募积分;
            case 20:
                return CT_将魂;
            case 21:
                return CT_装扮券;
            case 22:
                return CT_称号;
            case 23:
                return CT_头像框;
            case 24:
                return CT_形象;
            case 25:
                return CT_招贤积分;
            case 26:
                return CT_头像;
            case 27:
                return CT_VIP经验;
            case 28:
                return CT_普通夺宝积分;
            case 29:
                return CT_高级夺宝积分;
            case 30:
                return CT_联盟战积分;
            case 31:
                return CT_天梯积分;
            case 32:
                return CT_平叛积分;
            case 35:
                return CT_限时兑换积分;
            case 37:
                return CT_周卡_货币1;
            case 36:
                return CT_周卡_货币2;
            case 38:
                return CT_金锭;
            case 39:
                return CT_节日BOSS积分;
            case 40:
                return CT_节日BOSS兑换卷;
            case 41:
                return CT_兵符;
            default:
                return null;
        }
    }
}
